package com.cpecc.manager.wuzi;

import java.util.Date;
import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.cpecc.dao.wuzi.FenTanDao;
import com.cpecc.model.wuzi.FenTan;
import com.cpecc.model.wuzi.WuZi;

@Service
@Transactional
public class FenTanManager {

	@Autowired
	private FenTanDao fenTanDao;
	
	public List<FenTan> getFenTanBM(WuZi wuZi){
		return fenTanDao.getFenTanBM(wuZi);
	}
	
	public void save(FenTan fenTan){
		fenTanDao.save(fenTan);
	}
	
	public FenTan get(String id){
		return fenTanDao.get(id);
	}
	
	public boolean cover(FenTan fenTan){
		return fenTanDao.cover(fenTan);
	}
	
	public boolean chongFu(String wuZiId,String depId){
		return fenTanDao.chongFu(wuZiId, depId);
	}
	
	public void quChuFenTan(WuZi wuZi,Date date){
		fenTanDao.quChuFenTan(wuZi, date);
	}
	
	public List<FenTan> getAllFenTanList(WuZi wuZi){
		return fenTanDao.getAllFenTanList(wuZi);
	}	
	
	public void huiFuFenTan(WuZi wuZi){
		fenTanDao.huiFuFenTan(wuZi);
	}
}
